#include<bits/stdc++.h>
using namespace std;
#define int long long
bool cmp(string s1, string s2)
{
	return s1 < s2;
}
signed main()
{
	string ss;
//	int k = 0;
	set<string> s;
	while (cin >> ss) {
		s.insert(ss);
	}

	for (set<string>::iterator it = s.begin(); it != s.end(); it++) {
//		cout << s[k];
		cout << *it << endl;
	}
	return 0;
}
